<?php

use yii\helpers\Url;
?>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
    <head><meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
        <title>注册</title>
        <link href="/css/style.default.css" rel="stylesheet" />
        <link href="/css/validate.css" rel="stylesheet" />
        <script src="/js/jquery-1.11.1.min.js"></script>
        <script src="/js/jquery-migrate-1.2.1.min.js"></script>
        <script src="/js/bootstrap.min.js"></script>
        <script src="/js/modernizr.min.js"></script>
        <script src="/js/jquery.sparkline.min.js"></script>
        <script src="/js/jquery.cookies.js"></script>
        <script src="/js/toggles.min.js"></script>
        <script src="/js/retina.min.js"></script>
        <script src="/js/select2.min.js"></script>
        <link href="/js/ui-dialog.css" rel="stylesheet" />
        <script src="/js/custom.js"></script>
        <script type="text/javascript" charset="utf-8" src="/js/dialog-plus-min.js"></script>
        <script type="text/javascript" charset="utf-8" src="/js/jquery.form.min.js"></script>
        <script type="text/javascript" charset="utf-8" src="/js/Validform_v5.3.2_min.js"></script>
        <script type="text/javascript" charset="utf-8" src="/js/register-validate.js"></script>
        <!-- HTML5 shim and Respond.js IE8 support of HTML5 elements and media queries -->
        <!--[if lt IE 9]>
      <script src="js/html5shiv.js"></script>
      <script src="js/respond.min.js"></script>
      <![endif]-->
    </head>
    <body>
        <section>
            <style type="text/css">
                .navs {
                    line-height: 50px;
                    margin-left: 30px;
                    font-size: 17px;
                    float: left;
                    color: black;
                    text-decoration: none;
                }
                .navs:hover {
                    text-decoration: none;
                }
                .contentpanel{
                    margin: 0 auto;
                    width: 50%;
                }
            </style>
            <div class="contentpanel">
                <div class="panel panel-default">
                    <div class="panel-heading"><h3 class="panel-title">注册</h3></div>
                    <div class="panel-body">
                        <!-- col-sm-6 -->
                        <div class="col-md-6" style="float: none; margin: 0 auto;">
                            <form id="regform" url="<?php Url::toRoute(["site/signup"]) ?>">
                                <div class="mb10">
                                    <label class="control-label">登录名</label>
                                    <input id="txtUserName" name="username" type="text" class="form-control input txt" placeholder="输入登录用户名" datatype="s3-50" nullmsg="请输入登录的用户名" sucmsg=" " ajaxurl="<?php echo Url::toRoute(["submitregajax", "action" => "username"]) ?>" />
                                </div>
                                <div class="mb10">
                                    <label class="control-label">密码</label>
                                    <input id="txtPassword" name="password" type="password" class="form-control input txt" placeholder="输入登录密码" datatype="*6-20" nullmsg="请输入登录密码" errormsg="密码范围在6-20位之间" sucmsg=" " />
                                </div>
                                <div class="mb10">
                                    <label class="control-label">重复密码</label>
                                    <input id="txtPassword1" name="repassword" type="password" class="form-control input txt" placeholder="请再次输入密码" datatype="*" recheck="password" nullmsg="请再输入一次密码" errormsg="两次输入的密码不一致" sucmsg=" " />
                                </div>
                                <div class="mb10">
                                    <label class="control-label">邀请码</label>
                                    <input id="txtCode" name="invite_code" type="text" class="form-control input txt" placeholder="输入邀请码" datatype="s6-6" errormsg="邀请码格式不正确" nullmsg="请输入邀请码" sucmsg=" " ajaxurl="<?php echo Url::toRoute(["submitregajax", "action" => "validate_invitation"]) ?>" />
                                </div>
                                <div class="mb10">
                                    <label class="control-label">真实姓名</label>
                                    <input id="txtTrueName" name="truename" type="text" class="form-control input txt" placeholder="输入真实姓名" datatype="s2-50" nullmsg="请输入真实姓名" sucmsg=" " />
                                </div>
                                <div class="mb10">
                                    <label class="control-label">支付宝账号</label>
                                    <input id="txtEmail" name="alipay" type="text" class="form-control input txt" placeholder="输入支付宝账号,输入后不可更改" datatype="*" nullmsg="输入支付宝账号" sucmsg=" " ajaxurl="<?php echo Url::toRoute(["submitregajax", "action" => "validate_alipay"]) ?>" />
                                </div>
                                <div class="mb10">
                                    <label class="control-label">手机号</label>
                                    <input id="txtMobile" name="phone" type="text" class="form-control input txt" placeholder="输入手机号码" datatype="m" nullmsg="请输入手机号码" sucmsg=" " />
                                </div>
                                <div class="mb10">
                                    <label class="control-label">QQ</label>
                                    <input id="txtQQ" name="qq" type="text" class="form-control input txt" placeholder="输入QQ" datatype="*" nullmsg="请输入QQ" errormsg="密码范围在6-20位之间请输入QQ" sucmsg=" " />
                                </div>
                                <input name="btnSubmit" type="submit" id="btnSubmit" class="btn btn-success btn-block" value="注册" />
                            </form>
                        </div>
                        <!-- col-sm-6 -->
                    </div>
                </div>
                <!-- panel-body -->
            </div>
        </section>
        <script>
            jQuery(document).ready(function () {
                jQuery(".select2").select2({
                    width: '100%',
                    minimumResultsForSearch: -1
                });
                jQuery(".select2-2").select2({
                    width: '100%'
                });
                var c = jQuery.cookie('change-skin');
                if (c && c == 'greyjoy') {
                    jQuery('.btn-success').addClass('btn-orange').removeClass('btn-success');
                } else if (c && c == 'dodgerblue') {
                    jQuery('.btn-success').addClass('btn-primary').removeClass('btn-success');
                } else if (c && c == 'katniss') {
                    jQuery('.btn-success').addClass('btn-primary').removeClass('btn-success');
                }
            });
        </script>
    </body>
</html>
